package org.terramagnet.pdmviewer.parser;

import java.util.LinkedHashMap;
import java.util.Map;

public class PDM extends PDMObject{

    private String id;
    private String name;
    private String code;
    private String dbmsCode;
    private String dbmsName;
    private final Map<String, PDMPhysicalDiagram> physicalDiagrams = new LinkedHashMap<>();
    private final Map<String, PDMUser> users = new LinkedHashMap<>();
    private final Map<String, PDMTable> tables = new LinkedHashMap<>();
    private final Map<String, PDMReference> references = new LinkedHashMap<>();

    /**
     * @return the id
     */
	@Override
    public String getId() {
        return id;
    }

    /**
     * @param id the id to set
     */
    public void setId(String id) {
        this.id = id;
    }

    /**
     * @return the name
     */
    public String getName() {
        return name;
    }

    /**
     * @param name the name to set
     */
    public void setName(String name) {
        this.name = name;
    }

    /**
     * @return the code
     */
    public String getCode() {
        return code;
    }

    /**
     * @param code the code to set
     */
    public void setCode(String code) {
        this.code = code;
    }

    /**
     * @return the physicalDiagrams
     */
    public Map<String, PDMPhysicalDiagram> getPhysicalDiagrams() {
        return physicalDiagrams;
    }

    /**
     * @return the users
     */
    public Map<String, PDMUser> getUsers() {
        return users;
    }

    /**
     * @return the tables
     */
    public Map<String, PDMTable> getTables() {
        return tables;
    }

    /**
     * @return the references
     */
    public Map<String, PDMReference> getReferences() {
        return references;
    }

    /**
     * @return the dbmsCode
     */
    public String getDbmsCode() {
        return dbmsCode;
    }

    /**
     * @param dbmsCode the dbmsCode to set
     */
    public void setDbmsCode(String dbmsCode) {
        this.dbmsCode = dbmsCode;
    }

    /**
     * @return the dbmsName
     */
    public String getDbmsName() {
        return dbmsName;
    }

    /**
     * @param dbmsName the dbmsName to set
     */
    public void setDbmsName(String dbmsName) {
        this.dbmsName = dbmsName;
    }

    @Override
    public String toString() {
        return "PDM{" + "id=" + id + ", name=" + name + ", code=" + code + ", dbmsCode=" + dbmsCode + ", dbmsName=" + dbmsName + ", physicalDiagrams=" + physicalDiagrams + ", users=" + users + ", tables=" + tables + ", references=" + references + '}';
    }

}
